package com.ruoyi.system.domain.vo;

import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.util.Objects;

public class UnitVo extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /** 主键(自增) */
    private Long id;

    /** 单元名称 */
    @Excel(name = "单元名称")
    private String name;

    /** 楼宇id */
    @Excel(name = "楼宇id")
    private Long buildingId;

    @Excel(name = "楼宇名称")
    private String buildingName;

    /** 创建人 */
    @Excel(name = "创建人")
    private String creator;

    @Excel(name = "楼层数")
    private Long floorNum;

    /** 删除标记，0为删除，1已删除 */
    private String delFlag;

    public UnitVo() {}

    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId()
    {
        return id;
    }
    public void setName(String name)
    {
        this.name = name;
    }

    public String getName()
    {
        return name;
    }
    public void setBuildingId(Long buildingId)
    {
        this.buildingId = buildingId;
    }

    public Long getBuildingId()
    {
        return buildingId;
    }
    public void setCreator(String creator)
    {
        this.creator = creator;
    }

    public String getCreator()
    {
        return creator;
    }
    public void setDelFlag(String delFlag)
    {
        this.delFlag = delFlag;
    }

    public String getDelFlag()
    {
        return delFlag;
    }

    public String getBuildingName() {
        return buildingName;
    }

    public void setBuildingName(String buildingName) {
        this.buildingName = buildingName;
    }

    public Long getFloorNum() {
        return floorNum;
    }

    public void setFloorNum(Long floorNum) {
        this.floorNum = floorNum;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        UnitVo unitVo = (UnitVo) o;
        return Objects.equals(id, unitVo.id) && Objects.equals(name, unitVo.name) && Objects.equals(buildingId, unitVo.buildingId) && Objects.equals(buildingName, unitVo.buildingName) && Objects.equals(creator, unitVo.creator) && Objects.equals(floorNum, unitVo.floorNum) && Objects.equals(delFlag, unitVo.delFlag);
    }

    @Override
    public int hashCode() {
        return Objects.hash(id, name, buildingId, buildingName, creator, floorNum, delFlag);
    }

    @Override
    public String toString() {
        return "UnitVo{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", buildingId=" + buildingId +
                ", buildingName='" + buildingName + '\'' +
                ", creator='" + creator + '\'' +
                ", floorNum=" + floorNum +
                ", delFlag='" + delFlag + '\'' +
                '}';
    }

    public UnitVo(Long id, String name, Long buildingId, String buildingName, String creator, Long floorNum, String delFlag) {
        this.id = id;
        this.name = name;
        this.buildingId = buildingId;
        this.buildingName = buildingName;
        this.creator = creator;
        this.floorNum = floorNum;
        this.delFlag = delFlag;
    }
}
